{
 "cells": [
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "### When should I use datashader?\n",
    "\n",
    "Datashader is designed for working with large datasets, for\n",
    "cases where it is most crucial to faithfully represent the\n",
    "*distribution* of your data.  datashader can work easily with\n",
    "extremely large datasets, generating a fixed-size data structure\n",
    "(regardless of the original number of records) that gets transferred to\n",
    "your local browser for display.  If you ever find yourself subsampling\n",
    "your data just so that you can plot it feasibly, or if you are forced\n",
    "for practical reasons to iterate over chunks of it rather than looking\n",
    "at all of it at once, then datashader can probably help you."
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "### When should I *not* use datashader?\n",
    "\n",
    "If you have a very small number of data points (in the hundreds\n",
    "or thousands) or curves (in the tens or several tens, each with\n",
    "hundreds or thousands of points), then conventional plotting packages\n",
    "like [Bokeh](https://bokeh.pydata.org) may be more suitable.  With conventional browser-based\n",
    "packages, all of the data points are passed directly to the browser for\n",
    "display, allowing specific interaction with each curve or point,\n",
    "including display of metadata, linking to sources, etc.  This approach\n",
    "offers the most flexibility *per point* or *per curve*, but rapidly\n",
    "runs into limitations on how much data can be processed by the browser,\n",
    "and how much can be displayed on screen and resolved by the human\n",
    "visual system.  If you are not having such problems, i.e., your data is\n",
    "easily handled by your plotting infrastructure and you can easily see\n",
    "and work with all your data onscreen already, then you probably don't\n",
    "need datashader."
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "### Is datashader part of Bokeh?\n",
    "\n",
    "Datashader is an independent project, focusing on generating\n",
    "aggregate arrays and representations of them as images.  Bokeh is a\n",
    "complementary project, focusing on building browser-based\n",
    "visualizations and dashboards.  Bokeh (along with other plotting\n",
    "packages) can display images rendered by datashader, providing axes,\n",
    "interactive zooming and panning, selection, legends, hover\n",
    "information, and so on.  Sample bokeh-based plotting code is provided\n",
    "with datashader, but viewers for maptlotlib are already under\n",
    "development, and similar code could be developed for any other\n",
    "plotting package that can display images.  The library can also be\n",
    "used separately, without any external plotting packages, generating\n",
    "images that can be displayed directly or saved to disk, or generating\n",
    "aggregate arrays suitable for further analysis."
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "### What's the easiest way to use datashader interactively?\n",
    "\n",
    "[HoloViews](https://holoviews.org). HoloViews uses Bokeh behind\n",
    "the scenes, but it offers a higher level API that is well suited to\n",
    "the sorts of magic that allow interactive use of Datashader. For a\n",
    "given dataset, HoloViews can easily construct either a raw Bokeh plot\n",
    "or a Bokeh plot with server-side rendering from Datashader, hiding\n",
    "nearly all of the complexity involved.\n",
    "\n"
   ]
  }
 ],
 "metadata": {
  "language_info": {
   "name": "python",
   "pygments_lexer": "ipython3"
  }
 },
 "nbformat": 4,
 "nbformat_minor": 2
}
